package com.yupi.springbootinit.service;

import com.yupi.springbootinit.common.ErrorCode;
import com.yupi.springbootinit.exception.BusinessException;
import com.yupi.springbootinit.exception.ThrowUtils;
import com.yupi.springbootinit.model.entity.Comment;
import com.baomidou.mybatisplus.extension.service.IService;
import com.yupi.springbootinit.model.entity.Post;
import org.apache.commons.lang3.StringUtils;
import org.springframework.web.multipart.MultipartFile;

import java.util.List;

/**
* @author LENOVO
* @description 针对表【comment(评论)】的数据库操作Service
* @createDate 2024-09-18 08:40:59
*/
public interface CommentService extends IService<Comment> {

    List getComment(Long id);


    /**
     * 验证评论
     * */
    void validComment(Comment comment, boolean add);

    List<String> uploadImage(List<MultipartFile> files);


    boolean deleteCommentImage(String fileName);

    boolean deleteOldComment(Long postId);
}
